<?php

namespace AdminBundle\Controller;

use AdminBundle\Entity\TaskJobSchedules;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Method;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route;

/**
 * Taskjobschedule controller.
 *
 * @Route("taskjobschedules")
 */
class TaskJobSchedulesController extends Controller
{
    /**
     * Lists all taskJobSchedule entities.
     *
     * @Route("/", name="taskjobschedules_index")
     * @Method("GET")
     */
    public function indexAction()
    {
        $em = $this->getDoctrine()->getManager();

        $taskJobSchedules = $em->getRepository('AdminBundle:TaskJobSchedules')->findAll();

        return $this->render('taskjobschedules/index.html.twig', array(
            'taskJobSchedules' => $taskJobSchedules,
        ));
    }

    /**
     * Finds and displays a taskJobSchedule entity.
     *
     * @Route("/{id}", name="taskjobschedules_show")
     * @Method("GET")
     */
    public function showAction(TaskJobSchedules $taskJobSchedule)
    {

        return $this->render('taskjobschedules/show.html.twig', array(
            'taskJobSchedule' => $taskJobSchedule,
        ));
    }
}
